<link href="../addons/jy_mapfuwu/custom/templates/mobile/style.css?v=201705251730" rel="stylesheet">

<style>
    .fui-list{
        background: #fff;
    }
    .fui-list:first-child{
        margin-top: 0rem;
    }
    .fui-list.particulars{
        height: 3rem;
        padding:.4rem 0;
    }
    .fui-list.particulars div{
        -webkit-box-flex: 1;
        -webkit-flex: 1;
        -ms-flex: 1;
        flex: 1;
        text-align: center;
        font-size: .55rem;
        border-right: 1px solid #ededed;
        color: #000;
    }
    .fui-list.particulars div:last-child{border: 0}
</style>
<div class="fui-page fui-page-current page-commission-log">
    <div class="fui-header">
        <div class="fui-header-left">
            <a class="back" ng-click="goback();"></a>
        </div>
        <div class="title">已申请({{pagedata.balance_total ||0.00}})</div>
    </div>
    <div class="fui-content">
	 <div class="fui-tab fui-tab-warning" id="tab">
				<a href="javascript:;" ng-class="{'active':pagedata.params.status==0}" ng-click="pagedata.loaded=false;pagedata.params.status=0;pagedata.get_list()">待审核</a>
				<a href="javascript:;" ng-class="{'active':pagedata.params.status==1}" ng-click="pagedata.loaded=false;pagedata.params.status=1;pagedata.get_list()">待打款</a>
				<a href="javascript:;" ng-class="{'active':pagedata.params.status==3}" ng-click="pagedata.loaded=false;pagedata.params.status=3;pagedata.get_list()">已打款</a>
				<a href="javascript:;" ng-class="{'active':pagedata.params.status==2}" ng-click="pagedata.loaded=false;pagedata.params.status=2;pagedata.get_list()">无效</a>
	 </div>
        <div ng-if="pagedata.list.length>0" class="fui-list-group" style="padding:0.4rem 0">
		<div ng-repeat="item in pagedata.list" class="fui-list" style="height: 3.5rem">	
			<div class="fui-list-inner">
				<div class="row">
				      <div class="row-text" >
					 
					 结算单号: {{item.balancesn}}
					 
				      </div>
				</div>
				<div  class="subtitle">
				    结算佣金：{{item.money}}
				    
				    
				</div>
				<div  class="subtitle">
				    手续费：{{item.balance_pay}}
				    
				    
				</div>
				<div ng-if="item.status==3" class="subtitle">
				    打款时间：{{item.pay_time}}
				</div>
				<div ng-if="item.status==2" class="subtitle">
				    不通过原因：{{item.remark}}
				</div>
			</div>
			<div  ng-if="item.status==3" class="row-remark">
				<p>实际打款:{{item.final_money}}元</p>
				<p>打款方式：{{item.pay_type}}</p>
			</div>
			<div ng-if="item.status!=3" class="row-remark">
                <span ng-if="item.status==0" class='fui-label fui-label-default'>待审核</span>
				<span ng-if="item.status==1" class='fui-label fui-label-default'>待打款</span>
				<!--<div ng-if="item.status==2" class='fui-label fui-label-default'>无效</div>-->
				<div ng-if="item.status==2" href="javascript:;" ng-click="pagedata.post=item;pagedata.post.pay_type=item.newpay_type;pagedata.showremark=true" class='btn btn-sm btn-default-o'>重新申请</div>
			</div>
		</div>
		</div>
		<div ng-if="pagedata.list.length==0" class='content-empty' >
			<!--<i class='icon icon-group'></i><br/>暂时没有任何数据-->
			<img src="../core/resource/images/nomeb.png" style="width: 6rem;margin-bottom: .5rem;"><br/><p style="color: #999;font-size: .75rem">暂时没有任何数据</p>
		</div>

    </div>
</div>
<div ng-if="pagedata.showremark" class="popup">
	<div class="popup-body">
		<div class="popup-bottom">
			<i class="closed icon icon-cuowu" ng-click="pagedata.showremark=false"></i>
			<div class="fui-cell-group">
				<div class="fui-cell">
					<div class="fui-cell-label" style="width:auto;font-size:0.9rem">重新申请说明</div>
				</div>
				<div class="fui-cell">
						<div class="fui-cell-label" style="width: 120px;"><span class="re-g">提现方式</span></div>
						<div class="fui-cell-info">
							<select id="applytype" ng-model="pagedata.post.pay_type">
								<option ng-repeat="(k,title) in pagedata.pay_types" value="{{k}}" ng-selected="pagedata.post.pay_type==k">{{title}}</option>
							</select>
						</div>
						<div class="fui-cell-remark"></div>
				</div>
				<div ng-if="pagedata.post.pay_type =='downline'" class="fui-cell alipay-group">
						<div class="fui-cell-label" style="width: 120px;">微信号</div>
						<div class="fui-cell-info">
						<input type="text" id="wechat" name="wechat" class='fui-input' ng-model="pagedata.post.wechat" value="{{pagedata.post.wechat}}" max="25"/>
						</div>
					</div>
					<div ng-if="pagedata.post.pay_type =='alipay' || pagedata.post.pay_type =='union'" class="fui-cell ab-group">
						<div class="fui-cell-label" style="width: 120px;">真实姓名</div>
						<div class="fui-cell-info"><input type="text" id="realname" name="realname" ng-model="pagedata.post.realname" class='fui-input' value="{{pagedata.post.realname}}" max="25"/></div>
					</div>
					<div ng-if="pagedata.post.pay_type =='alipay'" class="fui-cell alipay-group">
						<div class="fui-cell-label" style="width: 120px;">支付宝帐号</div>
						<div class="fui-cell-info">
						<input type="text" id="alipay" name="alipay" class='fui-input' ng-model="pagedata.post.alipay" value="{{pagedata.post.alipay}}" max="25"/>
						</div>
					</div>
					<div ng-if="pagedata.post.pay_type =='alipay'" class="fui-cell alipay-group">
							<div class="fui-cell-label" style="width: 120px;">确认帐号</div>
							<div class="fui-cell-info"><input type="text" id="alipay1" ng-model="pagedata.post.alipay1" name="alipay1" class='fui-input' value="{{pagedata.post.alipay1}}" max="25"/></div>
					</div>
					<div ng-if="pagedata.post.pay_type =='union'" class="fui-cell bank-group" >
							<div class="fui-cell-label" style="width: 120px;">所属银行</div>
							<div class="fui-cell-info">
								<input type="text" name="bankname" class='fui-input' ng-model="pagedata.post.bankname" value="{{pagedata.post.bankname}}"/>
							</div>
					</div>
					<div ng-if="pagedata.post.pay_type =='union'" class="fui-cell bank-group">
							<div class="fui-cell-label" style="width: 120px;">银行卡号</div>
							<div class="fui-cell-info"><input type="text" id="bankcard" name="bankcard" class='fui-input' ng-model="pagedata.post.bankcard" value="{{pagedata.post.bankcard}}" max="25"/></div>
					</div>
					<div ng-if="pagedata.post.pay_type =='union'" class="fui-cell bank-group">
							<div class="fui-cell-label" style="width: 120px;">确认卡号</div>
							<div class="fui-cell-info"><input type="text" id="bankcard1" name="bankcard1" class='fui-input' ng-model="pagedata.post.bankcard1" value="{{pagedata.post.bankcard1}}" max="25"/></div>
					</div>
					<div class="fui-cell alipay-group">
						<div class="fui-cell-label" style="width: 120px;">联系电话</div>
						<div class="fui-cell-info">
						<input type="text" id="mobile" name="mobile" class='fui-input' ng-model="pagedata.post.mobile" value="{{pagedata.post.mobile}}" max="25"/>
						</div>
				</div>
				<div class="fui-cell">
					<div class="fui-cell-info c000">
						<textarea rows="5" placeholder="50字以内（选填）" ng-model="pagedata.post.remark"></textarea>
					</div>
				</div>
			</div>
			<div class="fui-navbar">
				<a href="javascript:;" ng-click="post(pagedata.post,'/balance/post/')"  aria-hidden="true" data-dismiss="modal" class="nav-item btn btn-danger confirmbtn">确定申请</a>
			</div>
		</div>
	</div>
</div>
<script>
scope.tool.get_list('jy_mapfuwu/san.balance/list/',true);
scope.pagedata.scroll_bottom=function(){
	scope.tool.get_list('jy_mapfuwu/san.balance/list/');
}
scope.pagedata.get_list=function(){
	scope.tool.get_list('jy_mapfuwu/san.balance/list/',true);
}
</script>

